package com.jy.books.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.jy.common.annotation.Excel;
import com.jy.common.core.domain.BaseEntity;

/**
 * 书籍管理对象 books
 * 
 * @author ruoyi
 * @date 2025-05-29
 */
public class Books extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 图书ID（唯一标识每本物理书） */
    private Long bookId;

    /** 图书标题 */
    @Excel(name = "图书标题")
    private String title;

    /** 国际标准书号（同一ISBN可能对应多本物理书） */
    private String isbn;

    /** 出版年份 */
    @Excel(name = "出版年份")
    private Long publicationYear;

    /** 图书类别 */
    @Excel(name = "图书类别")
    private String genre;

    /** 页数 */
    @Excel(name = "页数")
    private Long pages;

    /** 内容简介 */
    @Excel(name = "内容简介")
    private String summary;

    /** 作者ID */
    @Excel(name = "作者ID")
    private Long authorId;

    /** 出版社ID */
    @Excel(name = "出版社ID")
    private Long publisherId;

    /** 条形码（唯一标识每本物理书） */
    private String barcode;

    /** 图书状态 */
    @Excel(name = "图书状态")
    private String status;

    /** 存放位置 */
    @Excel(name = "存放位置")
    private String location;

    /** 购买日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "购买日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date purchaseDate;

    public void setBookId(Long bookId) 
    {
        this.bookId = bookId;
    }

    public Long getBookId() 
    {
        return bookId;
    }

    public void setTitle(String title) 
    {
        this.title = title;
    }

    public String getTitle() 
    {
        return title;
    }

    public void setIsbn(String isbn) 
    {
        this.isbn = isbn;
    }

    public String getIsbn() 
    {
        return isbn;
    }

    public void setPublicationYear(Long publicationYear) 
    {
        this.publicationYear = publicationYear;
    }

    public Long getPublicationYear() 
    {
        return publicationYear;
    }

    public void setGenre(String genre) 
    {
        this.genre = genre;
    }

    public String getGenre() 
    {
        return genre;
    }

    public void setPages(Long pages) 
    {
        this.pages = pages;
    }

    public Long getPages() 
    {
        return pages;
    }

    public void setSummary(String summary) 
    {
        this.summary = summary;
    }

    public String getSummary() 
    {
        return summary;
    }

    public void setAuthorId(Long authorId) 
    {
        this.authorId = authorId;
    }

    public Long getAuthorId() 
    {
        return authorId;
    }

    public void setPublisherId(Long publisherId) 
    {
        this.publisherId = publisherId;
    }

    public Long getPublisherId() 
    {
        return publisherId;
    }

    public void setBarcode(String barcode) 
    {
        this.barcode = barcode;
    }

    public String getBarcode() 
    {
        return barcode;
    }

    public void setStatus(String status) 
    {
        this.status = status;
    }

    public String getStatus() 
    {
        return status;
    }

    public void setLocation(String location) 
    {
        this.location = location;
    }

    public String getLocation() 
    {
        return location;
    }

    public void setPurchaseDate(Date purchaseDate) 
    {
        this.purchaseDate = purchaseDate;
    }

    public Date getPurchaseDate() 
    {
        return purchaseDate;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("bookId", getBookId())
            .append("title", getTitle())
            .append("isbn", getIsbn())
            .append("publicationYear", getPublicationYear())
            .append("genre", getGenre())
            .append("pages", getPages())
            .append("summary", getSummary())
            .append("authorId", getAuthorId())
            .append("publisherId", getPublisherId())
            .append("barcode", getBarcode())
            .append("status", getStatus())
            .append("location", getLocation())
            .append("purchaseDate", getPurchaseDate())
            .toString();
    }
}
